package engine.gui;

import engine.game.Manager;
import engine.graphics.Vertex2f;
import engine.objects.TexturedObject;

public class GameButtonBorder extends Border {

	private static final long serialVersionUID = 1L;

	public GameButtonBorder(Manager m, ParentObject parent) {
		super(m, parent);
		init(); 
	}
	
	public void init(){
		super.init(); 
		TexturedObject.addNewAnimationToObject(this.getUpperLeftTile(), "upperLeftTile", "gui",
				new Vertex2f[]{new Vertex2f(3,3)}, new Vertex2f[]{new Vertex2f(0,30)},0); 
		TexturedObject.addNewAnimationToObject(this.getUpperRightTile(), "upperRightTile", "gui",
				new Vertex2f[]{new Vertex2f(3,3)}, new Vertex2f[]{new Vertex2f(3,30)},0); 
		TexturedObject.addNewAnimationToObject(this.getLowerRightTile(), "lowerRightTile", "gui",
				new Vertex2f[]{new Vertex2f(3,3)}, new Vertex2f[]{new Vertex2f(6,30)},0); 
		TexturedObject.addNewAnimationToObject(this.getLowerLeftTile(), "lowerLeftTile", "gui",
				new Vertex2f[]{new Vertex2f(3,3)}, new Vertex2f[]{new Vertex2f(9,30)},0); 
		this.getLeftTile().subdivide(3, 3, "leftTile", "gui", 
				new Vertex2f[]{new Vertex2f(12, 30)});
		this.getUpperTile().subdivide(3, 3, "upperTile", "gui", 
				new Vertex2f[]{new Vertex2f(15, 30)});
		this.getRightTile().subdivide(3, 3, "rightTile", "gui", 
				new Vertex2f[]{new Vertex2f(18, 30)});
		this.getLowerTile().subdivide(3, 3, "lowerTile", "gui", 
				new Vertex2f[]{new Vertex2f(21, 30)});
	}

}
